Skip to content

feat(kilocode): configure and launch from cli#209

Merged
ymkiux merged 13 commits into
mainfrom
fix/orchestration-privacy-redaction-main
Jul 16, 2026
Merged

feat(kilocode): configure and launch from cli#209
ymkiux merged 13 commits into
mainfrom
fix/orchestration-privacy-redaction-main

Conversation

@awsl233777

@awsl233777 awsl233777 commented Jun 30, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • make codexmate kilo / codexmate kilocode launch KiloCode instead of being config-only commands
  • add codexmate kilo config <url> <key> <model> [--provider <id>] for pure KiloCode provider setup
  • add a Web UI KiloCode config tab that auto-syncs provider URL, API key, and model without exposing a Web UI launch button
  • keep the KiloCode provider UI/summary block available while defaulting blank provider/model to codexmate / gpt-5.3
  • load stored KiloCode config when the Web UI restores or enters the KiloCode config tab, so saved URL/provider/model reappear after restart
  • replace the KiloCode API key show/hide text button with eye / eye-off icons while preserving plaintext toggle behavior, preventing blur auto-save from clearing the key before toggle, and keeping accessibility labels
  • make the KiloCode config preview read-only via value binding, keep its cursor/default focus style non-editable, and allow provider summary cards to select/switch providers by double-click or Enter
  • add KiloCode CLI (@kilocode/cli, kilo / kilocode) to CLI install status and Docs install commands
  • document KiloCode support and install command in README
  • keep the README Star History section on the original Markdown embed after the <picture> variant failed to display reliably on GitHub
  • bump the package version to 0.1.3 and publish git tag v0.1.3 on the latest PR head
  • add a Docs tab card for currently installed CLI commands, showing detected command path and version from install-status

Validation

  • node --check cli.js
  • node --check web-ui/app.js
  • node --test tests/unit/kilocode-config-cli.test.mjs
  • npm run test:unit
  • npm run test:e2e
  • npm run lint
  • npm test
  • README KiloCode and Star History entries inspected with grep

Notes

  • This force-overwrites PR feat(kilocode): configure and launch from cli #209 per request.
  • CodeRabbit was not checked or triggered because this request did not authorize checking CodeRabbit.
  • API keys are not rehydrated into the input as plaintext after restart; the stored key is reused on save and shown only as configured/redacted state.

@coderabbitai

coderabbitai Bot commented Jun 30, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review
📝 Walkthrough

Walkthrough

The PR reworks orchestration into a privacy-masked Kilo webview flow, adds local AI provider management, shifts orchestration copy from preview-oriented to run-oriented language, and extends OpenAI chat provider selection and fallback handling with matching tests.

Changes

Orchestration UI, privacy, and local AI

Layer / File(s) Summary
Kilo host snapshot and shim
web-ui/modules/task-kilo-webview-host.mjs, web-ui/modules/app.computed.main-tabs.mjs, web-ui/modules/app.methods.task-orchestration.mjs, web-ui/app.js, web-ui/modules/app.methods.navigation.mjs
Defines Kilo webview message normalization, VS Code API shimming, host snapshot construction, app-level shim installation, and local-ai tab recognition.
Orchestration data and actions
web-ui/modules/app.computed.main-tabs.mjs, web-ui/modules/app.methods.task-orchestration.mjs
Updates workspace candidates, readiness computations, conversation text, toast handling, webview message dispatch, and orchestration state hydration to use privacy keys and run-oriented flow.
Privacy UI rendering and local AI panels
web-ui/partials/index/panel-orchestration.html, web-ui/res/web-ui-render.precompiled.js, web-ui/styles/task-orchestration.css, web-ui/partials/index/layout-header.html, web-ui/partials/index/panel-local-ai.html, web-ui/index.html, web-ui/styles.css, web-ui/styles/local-ai-service.css
Replaces orchestration rendering with privacy placeholders, adds the Kilo host card, adds the local AI tab and panel, and introduces the related styles and layout wiring.
Orchestration locale strings
web-ui/modules/i18n/locales/*.mjs
Adds and updates orchestration privacy, toast, workspace-choice, workspace-action, kilo-host, readiness, step, node, and local AI strings across all locales.
Updated UI and orchestration tests
tests/unit/*.test.mjs
Updates orchestration UI assertions for masked interpolation and sensitive inputs, adjusts toast and workspace expectations, and adds Kilo shim, snapshot, parity, and local AI coverage.

OpenAI chat provider management

Layer / File(s) Summary
Provider store and status resolution
cli.js
Introduces task-local OpenAI chat persistence, local AI status reporting, provider selection, and per-provider config resolution in the CLI.
Fallback execution and diagnostics
cli.js
Extends OpenAI chat task execution to try multiple providers, record attempts, and report fallback details in the output.
Provider and fallback tests
tests/unit/task-codex-exec-windows.test.mjs, tests/e2e/test-task-orchestration.js
Updates unit and e2e tests for task-local provider resolution, bridge config persistence, auth gating, fallback execution, and local AI service visibility.

Estimated code review effort: 5 (Critical) | ~120 minutes

Possibly related PRs

  • SakuraByteCore/codexmate#208 — Shares the orchestration control flow, /plan/readiness changes, and task orchestration UI wiring with this change set.
  • SakuraByteCore/codexmate#101 — Touches the same task orchestration execution path and plan/run state transitions that this PR extends with privacy masking and Kilo webview support.
  • SakuraByteCore/codexmate#86 — Modifies the orchestration UI and computed/method layers that this PR builds on with additional privacy and webview behavior.

Suggested reviewers: SurviveM, ymkiux

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title is related to the CLI/provider setup work, though it understates the broader Kilo orchestration UI and privacy changes.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/orchestration-privacy-redaction-main

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@awsl233777

Copy link
Copy Markdown
Collaborator Author

Implemented the privacy hotfix on top of current main as a single commit.

What changed:

  • Redacted visible orchestration workspace/thread/run/task identifiers, summaries, errors, provider/model metadata, output text, logs, and file paths.
  • Kept internal selection state intact while replacing visible UI copy with neutral selected/hidden/count labels.
  • Updated all locale files and regenerated web-ui/res/web-ui-render.precompiled.js.
  • Added regression assertions for orchestration template/helper redaction.

Validation actually run:

  • Targeted orchestration sensitive-field scan: PRIVACY_SCAN_OK.
  • node tests/unit/run.mjs tests/unit/i18n-locales.test.mjs tests/unit/config-tabs-ui.test.mjs tests/unit/web-ui-source-bundle.test.mjs tests/unit/web-ui-logic.test.mjsAll 740 tests passed.

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Jun 30, 2026

Copy link
Copy Markdown
Contributor

@awsl233777 Reviewing the updated privacy hotfix now.

✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
web-ui/modules/app.methods.task-orchestration.mjs (1)

259-269: 🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

Route the new redaction placeholders through i18n.

These helpers now surface hardcoded English strings, so non-English locales will still see (output hidden) and (N log entries hidden) in the orchestration detail view even though this PR adds locale-backed privacy copy elsewhere.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@web-ui/modules/app.methods.task-orchestration.mjs` around lines 259 - 269,
The new redaction placeholders in formatTaskNodeLogs and
formatTaskNodeOutputText are hardcoded English strings, so replace them with
locale-backed messages from i18n. Update these helpers to use the existing
translation mechanism for the hidden output/log variants, keeping the same
conditional logic while routing both “no logs” and hidden-output text through
the orchestration detail view’s localized privacy copy.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@web-ui/modules/i18n/locales/ja.mjs`:
- Around line 972-977: The new orchestration privacy label for provider-hidden
is still in English, so update the Japanese locale entry in ja.mjs to use a
proper Japanese translation for the orchestration.privacy.providerHidden key.
Keep the surrounding privacy strings consistent with the other entries in this
section and verify the key remains aligned with the existing localization
object.

---

Outside diff comments:
In `@web-ui/modules/app.methods.task-orchestration.mjs`:
- Around line 259-269: The new redaction placeholders in formatTaskNodeLogs and
formatTaskNodeOutputText are hardcoded English strings, so replace them with
locale-backed messages from i18n. Update these helpers to use the existing
translation mechanism for the hidden output/log variants, keeping the same
conditional logic while routing both “no logs” and hidden-output text through
the orchestration detail view’s localized privacy copy.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 52abbd79-44c2-493b-8c4e-3179642eec9e

📥 Commits

Reviewing files that changed from the base of the PR and between a088933 and f4b2f57.

📒 Files selected for processing (11)
  • tests/unit/config-tabs-ui.test.mjs
  • tests/unit/web-ui-logic.test.mjs
  • web-ui/modules/app.computed.main-tabs.mjs
  • web-ui/modules/app.methods.task-orchestration.mjs
  • web-ui/modules/i18n/locales/en.mjs
  • web-ui/modules/i18n/locales/ja.mjs
  • web-ui/modules/i18n/locales/vi.mjs
  • web-ui/modules/i18n/locales/zh-tw.mjs
  • web-ui/modules/i18n/locales/zh.mjs
  • web-ui/partials/index/panel-orchestration.html
  • web-ui/res/web-ui-render.precompiled.js
📜 Review details
🔇 Additional comments (10)
tests/unit/config-tabs-ui.test.mjs (1)

159-169: LGTM!

tests/unit/web-ui-logic.test.mjs (1)

1896-1896: LGTM!

Also applies to: 2065-2067

web-ui/partials/index/panel-orchestration.html (7)

178-182: LGTM!

Also applies to: 195-195


259-261: LGTM!

Also applies to: 322-325, 348-351


397-407: LGTM!


409-441: LGTM!


482-487: 🔒 Security & Privacy

Confirm intended UX of switching workspacePath/threadId to type="password".

These are not secrets but user-editable values; type="password" masks the user's own input, preventing them from verifying or editing the path/id they typed, and some browsers/extensions still treat password fields specially even with autocomplete="off". If the goal is only to avoid shoulder-surfing/screen-share leakage, a reveal toggle or a CSS text-masking approach would preserve editability while keeping the masking. Please confirm this tradeoff is intended.


548-548: LGTM!


408-408: 🔒 Security & Privacy

Keep redaction on the remaining orchestration errors. web-ui/partials/index/panel-orchestration.html:145 and :376 still render taskOrchestration.lastError and taskOrchestration.selectedRunError verbatim, and both are populated from res.error / caught exception messages. If either API can surface backend/provider detail, these paths need the same masking as run.error.

web-ui/res/web-ui-render.precompiled.js (1)

4258-4258: 🗄️ Data Integrity & Integration

Bundle matches the template for these privacy bindings.

Comment thread web-ui/modules/i18n/locales/ja.mjs Outdated
@awsl233777

Copy link
Copy Markdown
Collaborator Author

Updated after the workspace selector/privacy re-check.

Additional fixes:

  • Kept workspace selection usable while preventing the selector labels/meta from exposing real paths or path tail names. The UI now shows neutral workspace choices, but still uses the internal path for selection.
  • Routed output/log redaction placeholders through i18n instead of hardcoded English strings.
  • Added regression assertions that workspace selector labels/meta do not expose /repo, codexmate, or other path-derived names.

Validation actually run after this update:

  • Targeted orchestration sensitive-field scan: PRIVACY_SCAN_OK.
  • node tests/unit/run.mjs tests/unit/i18n-locales.test.mjs tests/unit/config-tabs-ui.test.mjs tests/unit/web-ui-source-bundle.test.mjs tests/unit/web-ui-logic.test.mjsAll 740 tests passed.

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Jun 30, 2026

Copy link
Copy Markdown
Contributor

@awsl233777 Reviewing the updated privacy fixes now, including the workspace selector redaction and i18n-backed placeholder changes.

✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@awsl233777

Copy link
Copy Markdown
Collaborator Author

Handled the remaining CodeRabbit locale comment.

Additional fix:

  • Localized the Japanese privacy labels that still used English (workspace.selected, thread.selected, providerHidden).

Validation actually run after this update:

  • Targeted orchestration sensitive-field scan: PRIVACY_SCAN_OK.
  • node tests/unit/run.mjs tests/unit/i18n-locales.test.mjs tests/unit/config-tabs-ui.test.mjs tests/unit/web-ui-source-bundle.test.mjs tests/unit/web-ui-logic.test.mjsAll 740 tests passed.

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Jun 30, 2026

Copy link
Copy Markdown
Contributor

@awsl233777 Thanks for the update — I see the Japanese privacy labels were localized and the validation still passed (PRIVACY_SCAN_OK, 740/740 tests). I’ll review the latest changes now.


If you found this review helpful, would you consider giving us a shout-out on X?

Thank you for using CodeRabbit!

✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@awsl233777

Copy link
Copy Markdown
Collaborator Author

Updated this PR with a076274:

  • Added a Kilo-style split workspace action in the orchestration sidebar.
  • Primary action starts a new session in the selected workspace.
  • Dropdown selects default/existing workspaces while keeping raw paths hidden (Workspace N / Path hidden).
  • Regenerated web-ui/res/web-ui-render.precompiled.js.

Validation actually run:

  • PRIVACY_SCAN_OK
  • node tests/unit/run.mjs tests/unit/i18n-locales.test.mjs tests/unit/config-tabs-ui.test.mjs tests/unit/web-ui-source-bundle.test.mjs tests/unit/web-ui-logic.test.mjsAll 740 tests passed.

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Jun 30, 2026

Copy link
Copy Markdown
Contributor

@awsl233777 Thanks — I’ll review the latest update, including the split workspace action and the privacy-preserving workspace selector changes.

✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@awsl233777

Copy link
Copy Markdown
Collaborator Author

Pushed 9425163 with follow-up privacy hardening:

  • Masked taskOrchestration.lastError and taskOrchestration.selectedRunError in the visible orchestration UI.
  • Replaced the advanced workspacePath / threadId type="password" inputs with normal type="text" inputs plus CSS text masking, so browsers do not treat these editable values as passwords.
  • Regenerated web-ui/res/web-ui-render.precompiled.js.
  • Added regression assertions for the masked errors, non-password inputs, CSS masking, and precompiled render output.

Validation actually run after this update:

  • PRIVACY_SCAN_OK
  • node tests/unit/run.mjs tests/unit/i18n-locales.test.mjs tests/unit/config-tabs-ui.test.mjs tests/unit/web-ui-source-bundle.test.mjs tests/unit/web-ui-logic.test.mjsAll 740 tests passed.

Note: the test command still prints an existing search_sessions.py --limit -1 argparse warning, but exits successfully with all listed tests passing.

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Jun 30, 2026

Copy link
Copy Markdown
Contributor

@awsl233777 Thanks — I’ll review the latest privacy-hardening update, including the masked orchestration errors, CSS-based text masking for advanced inputs, the regenerated precompiled bundle, and the added regression coverage.

✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@awsl233777

Copy link
Copy Markdown
Collaborator Author

@coderabbitai re-review

@coderabbitai

coderabbitai Bot commented Jun 30, 2026

Copy link
Copy Markdown
Contributor

@awsl233777 Re-reviewing the latest changes now.

✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (2)
web-ui/partials/index/panel-orchestration.html (2)

211-222: 🔒 Security & Privacy | 🟠 Major | ⚡ Quick win

Node IDs are still exposed in the “redacted” plan/detail views.

These blocks still render wave.nodeIds, node.id, and node.workflowId, so the UI can leak the exact orchestration identifiers this privacy hotfix is trying to hide. Please switch those fields to the same generic/count-based placeholders used elsewhere in this panel.

Also applies to: 436-440

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@web-ui/partials/index/panel-orchestration.html` around lines 211 - 222, The
redacted orchestration detail views are still leaking exact identifiers in the
wave/node render blocks. Update the template sections that iterate over
taskOrchestration.plan.waves and taskOrchestration.plan.nodes so they no longer
display wave.nodeIds, node.id, or node.workflowId. Replace those fields with the
same generic/count-based placeholders already used elsewhere in this panel,
keeping the visible structure but removing identifier-level detail.

54-63: 🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

Drop the menu roles here<details> plus buttons already provides usable native interaction, but role="menu" / role="menuitemradio" opt into the ARIA menu pattern without the arrow-key and focus management that pattern expects. Remove the roles or wire the full menu behavior.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@web-ui/partials/index/panel-orchestration.html` around lines 54 - 63, The
task workspace selector in panel-orchestration.html is using ARIA menu semantics
without the required keyboard/focus behavior. Update the markup around the
task-workspace-menu-panel and the v-for button items to remove role="menu" and
role="menuitemradio", or implement the full menu interaction pattern if you keep
them. Keep the native details/button behavior centered around
selectTaskWorkspace and the workspace.active state.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Outside diff comments:
In `@web-ui/partials/index/panel-orchestration.html`:
- Around line 211-222: The redacted orchestration detail views are still leaking
exact identifiers in the wave/node render blocks. Update the template sections
that iterate over taskOrchestration.plan.waves and taskOrchestration.plan.nodes
so they no longer display wave.nodeIds, node.id, or node.workflowId. Replace
those fields with the same generic/count-based placeholders already used
elsewhere in this panel, keeping the visible structure but removing
identifier-level detail.
- Around line 54-63: The task workspace selector in panel-orchestration.html is
using ARIA menu semantics without the required keyboard/focus behavior. Update
the markup around the task-workspace-menu-panel and the v-for button items to
remove role="menu" and role="menuitemradio", or implement the full menu
interaction pattern if you keep them. Keep the native details/button behavior
centered around selectTaskWorkspace and the workspace.active state.

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 7eaa0132-91e2-4982-a6d7-bbe0d4c0f02e

📥 Commits

Reviewing files that changed from the base of the PR and between a076274 and 9425163.

📒 Files selected for processing (4)
  • tests/unit/config-tabs-ui.test.mjs
  • web-ui/partials/index/panel-orchestration.html
  • web-ui/res/web-ui-render.precompiled.js
  • web-ui/styles/task-orchestration.css
🚧 Files skipped from review as they are similar to previous changes (3)
  • web-ui/styles/task-orchestration.css
  • tests/unit/config-tabs-ui.test.mjs
  • web-ui/res/web-ui-render.precompiled.js

@awsl233777

Copy link
Copy Markdown
Collaborator Author

Pushed eb8696f with the latest CodeRabbit follow-up fixes.

Additional fixes:

  • Removed ARIA menu/menuitemradio roles from the split workspace selector so it uses native details/button behavior instead of incomplete menu semantics.
  • Stopped rendering plan wave node IDs, plan node IDs, and workflow IDs in visible orchestration plan/detail views.
  • Redacted displayed dependency lists to localized dependency counts instead of exact dependency IDs.
  • Updated all locale files and regenerated web-ui/res/web-ui-render.precompiled.js.
  • Added regression assertions for the removed roles and hidden plan/node identifiers.

Validation actually run after this update:

  • Targeted orchestration sensitive-field scan: PRIVACY_SCAN_OK.
  • node tests/unit/run.mjs tests/unit/i18n-locales.test.mjs tests/unit/config-tabs-ui.test.mjs tests/unit/web-ui-source-bundle.test.mjs tests/unit/web-ui-logic.test.mjsAll 740 tests passed.

Note: the test command still prints the existing search_sessions.py --limit -1 argparse warning, but exits successfully with all listed tests passing.

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Jun 30, 2026

Copy link
Copy Markdown
Contributor

@awsl233777 Thanks — I’ll review the latest update, including the removed ARIA menu semantics, hidden plan/node/workflow identifiers, redacted dependency counts, regenerated precompiled bundle, and the added regression coverage.

✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (3)
web-ui/modules/app.methods.task-orchestration.mjs (2)

472-505: 🔒 Security & Privacy | 🟠 Major | ⚡ Quick win

Mask backend error text in orchestration toasts as well.

The success path is now generic, but the failure branches in these same flows still call showMessage(res.error | message, 'error') on Line 484, Lines 499-500, Lines 517-518, Lines 532-534, Lines 769-770, and Lines 784-785. That still exposes raw server error text in the visible UI, which can leak the thread/workspace/run details this privacy hotfix is trying to hide. Use localized generic error toasts here and keep the raw message only in internal state/logging if needed.

Also applies to: 507-540, 759-790

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@web-ui/modules/app.methods.task-orchestration.mjs` around lines 472 - 505,
The orchestration failure toasts still surface raw backend error text, so update
the error branches in runTaskOrchestration and the other affected
task-orchestration flows to use generic localized messages instead of res.error
or error.message. Keep the detailed backend error only in internal return
values, state, or logging if needed, and make sure showMessage is called with a
sanitized message in the identified orchestration methods.

496-496: 🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

Route the new success toasts through t(...).

These newly changed strings are hardcoded Chinese, so English/Vietnamese sessions will now mix locales even though this PR adds orchestration i18n coverage elsewhere. Please switch them to translation keys instead of literals.

Also applies to: 528-528, 754-754, 781-781

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@web-ui/modules/app.methods.task-orchestration.mjs` at line 496, The success
toast strings in task orchestration are still hardcoded Chinese, so route them
through the i18n helper instead of passing literals to showMessage. Update the
affected success paths in the task-orchestration methods (including the ones
around the start, progress, completion, and related orchestration flows) to use
t(...) translation keys so locale-specific sessions stay consistent.
web-ui/res/web-ui-render.precompiled.js (1)

4074-4090: 🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

Use a valid selection role for the workspace items. aria-checked on a plain button is invalid ARIA, so the active workspace state won’t be announced correctly. Restore matching radio/menuitemradio semantics or switch to native radio controls.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@web-ui/res/web-ui-render.precompiled.js` around lines 4074 - 4090, The
workspace item button in the workspace menu is using invalid ARIA by setting
aria-checked on a plain button, so update the selection control in the workspace
menu render logic to use matching radio-style semantics instead. Locate the
template block that renders each workspace item and either change the
element/role to menuitemradio or radio with the appropriate checked state, or
replace it with native radio controls, while keeping the active workspace state
announced correctly through the existing workspace.active handling.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Outside diff comments:
In `@web-ui/modules/app.methods.task-orchestration.mjs`:
- Around line 472-505: The orchestration failure toasts still surface raw
backend error text, so update the error branches in runTaskOrchestration and the
other affected task-orchestration flows to use generic localized messages
instead of res.error or error.message. Keep the detailed backend error only in
internal return values, state, or logging if needed, and make sure showMessage
is called with a sanitized message in the identified orchestration methods.
- Line 496: The success toast strings in task orchestration are still hardcoded
Chinese, so route them through the i18n helper instead of passing literals to
showMessage. Update the affected success paths in the task-orchestration methods
(including the ones around the start, progress, completion, and related
orchestration flows) to use t(...) translation keys so locale-specific sessions
stay consistent.

In `@web-ui/res/web-ui-render.precompiled.js`:
- Around line 4074-4090: The workspace item button in the workspace menu is
using invalid ARIA by setting aria-checked on a plain button, so update the
selection control in the workspace menu render logic to use matching radio-style
semantics instead. Locate the template block that renders each workspace item
and either change the element/role to menuitemradio or radio with the
appropriate checked state, or replace it with native radio controls, while
keeping the active workspace state announced correctly through the existing
workspace.active handling.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: aa08203e-dff7-4e11-bf15-6bceb42be9b4

📥 Commits

Reviewing files that changed from the base of the PR and between 9425163 and eb8696f.

📒 Files selected for processing (10)
  • tests/unit/config-tabs-ui.test.mjs
  • tests/unit/web-ui-logic.test.mjs
  • web-ui/modules/app.methods.task-orchestration.mjs
  • web-ui/modules/i18n/locales/en.mjs
  • web-ui/modules/i18n/locales/ja.mjs
  • web-ui/modules/i18n/locales/vi.mjs
  • web-ui/modules/i18n/locales/zh-tw.mjs
  • web-ui/modules/i18n/locales/zh.mjs
  • web-ui/partials/index/panel-orchestration.html
  • web-ui/res/web-ui-render.precompiled.js
✅ Files skipped from review due to trivial changes (2)
  • web-ui/modules/i18n/locales/ja.mjs
  • web-ui/modules/i18n/locales/zh-tw.mjs
🚧 Files skipped from review as they are similar to previous changes (4)
  • web-ui/modules/i18n/locales/zh.mjs
  • tests/unit/web-ui-logic.test.mjs
  • tests/unit/config-tabs-ui.test.mjs
  • web-ui/partials/index/panel-orchestration.html

@awsl233777

Copy link
Copy Markdown
Collaborator Author

Update pushed in e253c0c.

What changed:

  • Replaced task orchestration raw error toasts with localized generic privacy-safe messages.
  • Added localized orchestration toast strings for en, zh, zh-TW, ja, and vi.
  • Changed the workspace split action button from aria-checked to aria-pressed.
  • Added regression coverage to ensure raw API error details are not surfaced through toast messages.
  • Regenerated web-ui/res/web-ui-render.precompiled.js.

Validation actually run:

  • PRIVACY_SCAN_OK
  • node tests/unit/run.mjs tests/unit/i18n-locales.test.mjs tests/unit/config-tabs-ui.test.mjs tests/unit/web-ui-source-bundle.test.mjs tests/unit/web-ui-logic.test.mjsAll 741 tests passed
  • git diff --check → no output

Note: the existing search_sessions.py --limit -1 argparse warning still appears during the test command, but the command exits 0.

@coderabbitai re-review

@coderabbitai

coderabbitai Bot commented Jun 30, 2026

Copy link
Copy Markdown
Contributor

@awsl233777 Reviewing the latest update now, including the privacy-safe localized toast changes, the aria-pressed adjustment, the added regression coverage, and the regenerated precompiled bundle.

✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@awsl233777

Copy link
Copy Markdown
Collaborator Author

Implemented the Kilo-compatible orchestration host on this existing PR branch.

What changed:

  • Added a Codexmate-owned Kilo webview host shim for acquireVsCodeApi(), postMessage(), and getState/setState().
  • Added a whitelist-based task bridge for orchestration messages.
  • Explicitly blocks sensitive VSCode host escape hatches such as file open, external open, terminal, and agent-manager local actions.
  • Added a Kilo-style host card to the orchestration tab while preserving the existing workspace selector and task composer.
  • Kept workspace/thread/run/task/node/provider/model/endpoint/error details hidden in the visible UI.
  • Updated all locale files (en, zh, zh-TW, ja, vi) and regenerated the precompiled Web UI render.

Validation performed:

  • npm run test:unit — passed, 744 tests.
  • npm run test:e2e — passed.
  • npm run lint — passed for 231 files.
  • git diff --check — passed.
  • Local Web UI smoke screenshot at ?tab=orchestration confirmed the Kilo host card renders and visible sensitive details remain redacted.

Known existing noise:

  • Unit test output still includes the pre-existing search_sessions.py --limit -1 argparse warning, but the command exits 0.

@coderabbitai re-review

@coderabbitai

coderabbitai Bot commented Jun 30, 2026

Copy link
Copy Markdown
Contributor

@awsl233777 Thanks — I’ll re-review the latest update, including the Kilo-compatible orchestration host shim, the whitelist-based task bridge and blocked host escape hatches, the added orchestration host card, the preserved privacy redaction, and the regenerated precompiled render.

✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 5

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (3)
web-ui/modules/i18n/locales/zh.mjs (1)

1242-1259: 🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

Add the missing empty-state strings for node output and logs.

formatTaskNodeOutputText() and formatTaskNodeLogs() now look up orchestration.detail.node.output.empty and orchestration.detail.node.logs.empty, but zh.mjs still doesn't define them. In zh, empty sections will fall back to raw i18n keys.

Suggested fix
     'orchestration.detail.node.meta': '尝试 {attempts} 次 · 自动修复 {autoFix} 次',
     'orchestration.detail.node.step': '任务步骤',
+    'orchestration.detail.node.output.empty': '无输出',
+    'orchestration.detail.node.logs.empty': '无日志',
     'orchestration.openai.status.title': 'OpenAI Chat 运行配置',
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@web-ui/modules/i18n/locales/zh.mjs` around lines 1242 - 1259, Add the missing
zh locale entries for the empty-state labels used by formatTaskNodeOutputText()
and formatTaskNodeLogs(), since orchestration.detail.node.output.empty and
orchestration.detail.node.logs.empty are currently undefined in zh.mjs. Update
the locale object near the existing orchestration.detail.node.* strings so these
keys have proper Chinese fallback text, matching the other task node labels.
web-ui/partials/index/panel-orchestration.html (1)

269-270: 🔒 Security & Privacy | 🟠 Major | ⚡ Quick win

Drop node.kind from the masked plan node header.

Line 270 still appends node.kind, so the plan preview is leaking raw step metadata even though this view was otherwise converted to neutral labels and counts.

Suggested fix
-                                                            <div class="task-node-meta">{{ t('orchestration.detail.node.meta', { attempts: 0, autoFix: 0 }) }} · {{ node.kind }}</div>
+                                                            <div class="task-node-meta">{{ t('orchestration.detail.node.meta', { attempts: 0, autoFix: 0 }) }}</div>
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@web-ui/partials/index/panel-orchestration.html` around lines 269 - 270,
Remove the raw node kind from the masked plan node header in the orchestration
panel so the preview stays neutral. Update the header rendering in the plan node
markup to rely only on the translated title and meta counts, and drop the
`node.kind` append from the `task-node-meta` expression.
web-ui/modules/i18n/locales/vi.mjs (1)

1145-1145: 📐 Maintainability & Code Quality | 🟡 Minor | ⚡ Quick win

Finish localizing the new visible labels.

These two additions are still English, so the Vietnamese workspace picker and Kilo host panel will show mixed-language copy.

Also applies to: 1212-1212

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@web-ui/modules/i18n/locales/vi.mjs` at line 1145, The new visible labels in
the Vietnamese locale are still in English, so finish translating the workspace
picker and Kilo host panel strings in the locale map. Update the entries for
orchestration.workspace.choice.label and the other added label near the Kilo
host panel section in vi.mjs so they read naturally in Vietnamese and match the
surrounding translated keys.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@tests/unit/web-ui-logic.test.mjs`:
- Around line 1975-2022: The Kilo webview host snapshot test does not currently
cover redaction of conversationMessages, so raw prompt or assistant text could
still leak through createTaskKiloWebviewHostSnapshot. Update the snapshot helper
to redact or omit conversationMessages alongside the existing workspace, thread,
run, and ids sanitization, and extend this test to include a
conversationMessages payload and assert that the serialized snapshot does not
contain any raw message content.

In `@web-ui/modules/app.methods.task-orchestration.mjs`:
- Around line 900-936: `handleTaskKiloWebviewMessage` mutates
`this.taskOrchestration` directly when handling `sendMessage` and
`openSettingsPanel`, so make sure the orchestration state exists first. Call
`this.ensureTaskOrchestrationState()` at the start of
`handleTaskKiloWebviewMessage` (before reading or writing `chatDraft` or
`settingsOpen`) so the `taskOrchestration` object is always initialized before
any webview message can update it.
- Around line 938-952: Guard the `installTaskKiloWebviewShim` bootstrap against
`window.localStorage` access throwing in sandboxed or storage-disabled webviews,
and avoid replacing an existing `window.acquireVsCodeApi` bridge. Update the
`installTaskKiloWebviewShim` flow so it first checks whether a usable VS Code
API bridge already exists, then safely obtains storage (falling back if
unavailable) before calling `createTaskKiloVsCodeApiShim`, and only assigns
`window.acquireVsCodeApi` when no bridge is present.

In `@web-ui/modules/i18n/locales/ja.mjs`:
- Line 1065: The Kilo surface title string is still left in English, causing
mixed-language UI in the Japanese locale. Update the
`orchestration.kilo.surface.title` entry in `ja.mjs` to a proper Japanese
translation, keeping the key unchanged and matching the localization style used
by the other entries in this locale file.

In `@web-ui/modules/i18n/locales/zh-tw.mjs`:
- Line 1057: The orchestration.kilo.surface.title entry in the zh-TW locale is
still in English, so update this translation in zh-tw.mjs to a Traditional
Chinese string to keep the Kilo host UI consistent. Locate the locale mapping
for orchestration.kilo.surface.title and replace the current Webview surface
text with the proper zh-TW translation, matching the tone and terminology used
by nearby locale entries.

---

Outside diff comments:
In `@web-ui/modules/i18n/locales/vi.mjs`:
- Line 1145: The new visible labels in the Vietnamese locale are still in
English, so finish translating the workspace picker and Kilo host panel strings
in the locale map. Update the entries for orchestration.workspace.choice.label
and the other added label near the Kilo host panel section in vi.mjs so they
read naturally in Vietnamese and match the surrounding translated keys.

In `@web-ui/modules/i18n/locales/zh.mjs`:
- Around line 1242-1259: Add the missing zh locale entries for the empty-state
labels used by formatTaskNodeOutputText() and formatTaskNodeLogs(), since
orchestration.detail.node.output.empty and orchestration.detail.node.logs.empty
are currently undefined in zh.mjs. Update the locale object near the existing
orchestration.detail.node.* strings so these keys have proper Chinese fallback
text, matching the other task node labels.

In `@web-ui/partials/index/panel-orchestration.html`:
- Around line 269-270: Remove the raw node kind from the masked plan node header
in the orchestration panel so the preview stays neutral. Update the header
rendering in the plan node markup to rely only on the translated title and meta
counts, and drop the `node.kind` append from the `task-node-meta` expression.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 5a95fcfe-6294-4633-ae9a-c55ecfb669b0

📥 Commits

Reviewing files that changed from the base of the PR and between e253c0c and 115a8ee.

📒 Files selected for processing (15)
  • tests/unit/config-tabs-ui.test.mjs
  • tests/unit/web-ui-behavior-parity.test.mjs
  • tests/unit/web-ui-logic.test.mjs
  • web-ui/app.js
  • web-ui/modules/app.computed.main-tabs.mjs
  • web-ui/modules/app.methods.task-orchestration.mjs
  • web-ui/modules/i18n/locales/en.mjs
  • web-ui/modules/i18n/locales/ja.mjs
  • web-ui/modules/i18n/locales/vi.mjs
  • web-ui/modules/i18n/locales/zh-tw.mjs
  • web-ui/modules/i18n/locales/zh.mjs
  • web-ui/modules/task-kilo-webview-host.mjs
  • web-ui/partials/index/panel-orchestration.html
  • web-ui/res/web-ui-render.precompiled.js
  • web-ui/styles/task-orchestration.css
🚧 Files skipped from review as they are similar to previous changes (3)
  • tests/unit/config-tabs-ui.test.mjs
  • web-ui/modules/app.computed.main-tabs.mjs
  • web-ui/res/web-ui-render.precompiled.js
📜 Review details
🔇 Additional comments (4)
web-ui/modules/task-kilo-webview-host.mjs (1)

1-268: LGTM!

web-ui/app.js (1)

610-612: LGTM!

web-ui/modules/app.methods.task-orchestration.mjs (1)

273-296: LGTM!

Also applies to: 346-373, 449-466, 502-553, 577-640, 749-858

web-ui/partials/index/panel-orchestration.html (1)

556-561: 🔒 Security & Privacy

Verify the masking fallback for these sensitive inputs.

These fields now depend on task-sensitive-input, and the paired stylesheet change masks text with -webkit-text-security. If this panel ever runs outside a Chromium/WebKit webview, workspacePath and threadId will render in clear text again.

Comment thread tests/unit/web-ui-logic.test.mjs Outdated
Comment thread web-ui/modules/app.methods.task-orchestration.mjs Outdated
Comment thread web-ui/modules/app.methods.task-orchestration.mjs Outdated
Comment thread web-ui/modules/i18n/locales/ja.mjs Outdated
Comment thread web-ui/modules/i18n/locales/zh-tw.mjs Outdated
@awsl233777

Copy link
Copy Markdown
Collaborator Author

Updated the orchestration tab again to address the UI direction: this is no longer a small compatibility card added to the old layout.

What changed in this commit:

  • Reworked the orchestration tab into a Kilo/VSCode-style app shell:
    • dark activity rail
    • workspace/session sidebar
    • central chat/message surface
    • bottom prompt composer
    • right inspector/live trace/protocol panel
  • Kept the existing Codexmate orchestration actions wired through the new shell.
  • Preserved the Kilo-compatible acquireVsCodeApi() shim and whitelist bridge added earlier.
  • Preserved privacy redaction for workspace/thread/run/task/node/provider/model/endpoint/error details.
  • Updated the orchestration UI tests to assert the new Kilo-style shell instead of the previous three-column workbench layout.
  • Regenerated the precompiled Web UI render.

Validation performed after this rewrite:

  • npm run test:unit — passed, 744 tests.
  • npm run test:e2e — passed.
  • npm run lint — passed for 231 files.
  • git diff --check — passed.
  • Local Web UI smoke screenshot at ?tab=orchestration confirmed the tab now renders as a complete Kilo/VSCode-style shell and still hides visible sensitive details.

Known existing noise:

  • Unit test output still includes the pre-existing search_sessions.py --limit -1 argparse warning, but the command exits 0.

@coderabbitai re-review

@coderabbitai

coderabbitai Bot commented Jun 30, 2026

Copy link
Copy Markdown
Contributor

@awsl233777 Reviewing the latest orchestration shell rewrite now, including the Kilo/VSCode-style layout, preserved shim/bridge behavior, privacy redaction, updated UI tests, and regenerated precompiled render.

✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@web-ui/partials/index/panel-orchestration.html`:
- Line 65: The session picker is being artificially limited by the
taskOrchestrationWorkspaceSessions.slice(0, 10) usage in the panel-orchestration
template, which hides older sessions once there are more than ten. Update the
session rendering in this picker to use the full
taskOrchestrationWorkspaceSessions list, or introduce an explicit
show-more/loading pattern in the same UI so all sessions remain reachable from
the selector.
- Around line 219-225: Add a real masking fallback for the sensitive inputs in
the orchestration panel: `taskOrchestration.workspacePath` and
`taskOrchestration.threadId` currently depend only on `.task-sensitive-input` /
`-webkit-text-security`, so unsupported browsers show plain text. Update the
markup in `panel-orchestration.html` to use a password-style fallback or
equivalent masking behavior for these two fields, while preserving the existing
`v-model`, hints, and labels.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: be6e9271-428a-47e1-bf5f-616119f68219

📥 Commits

Reviewing files that changed from the base of the PR and between 115a8ee and 02440cd.

📒 Files selected for processing (4)
  • tests/unit/config-tabs-ui.test.mjs
  • web-ui/partials/index/panel-orchestration.html
  • web-ui/res/web-ui-render.precompiled.js
  • web-ui/styles/task-orchestration.css
🚧 Files skipped from review as they are similar to previous changes (1)
  • tests/unit/config-tabs-ui.test.mjs
📜 Review details
🧰 Additional context used
🪛 Stylelint (17.14.0)
web-ui/styles/task-orchestration.css

[error] 3246-3246: Expected empty line before declaration (declaration-empty-line-before)

(declaration-empty-line-before)

Comment thread web-ui/partials/index/panel-orchestration.html Outdated
Comment thread web-ui/partials/index/panel-orchestration.html Outdated
@awsl233777 awsl233777 changed the title fix(orchestration): redact private task details refactor(orchestration): replace tab with Kilo-style chat UI Jun 30, 2026
@awsl233777

Copy link
Copy Markdown
Collaborator Author

Updated the PR after the full orchestration tab rewrite.

What changed in the latest commit:

  • Replaced the orchestration tab template with a Kilo/VS Code-style chat surface: task header, status/timeline strip, message list, and prompt input.
  • Removed the old orchestration workbench/sidebar/inspector/quick-panel UI from the tab template and orchestration-specific stylesheet.
  • Reduced task-orchestration.css to the new tab surface styles instead of carrying the old workbench layout forward.
  • Generalized Kilo/orchestration-facing copy so the tab surface does not expose product/provider labels.
  • Kept the Kilo-compatible host shim and privacy redaction behavior.
  • Updated tests to fail if old UI class families or sensitive visible fields return.
  • Updated the PR title/body so they describe the current scope instead of the earlier redaction-only change.

Validation performed:

  • npm run test:unit — passed, 744 tests.
  • npm run test:e2e — passed.
  • npm run lint — passed for 231 files.
  • git diff --check — passed.
  • Source grep gate passed for the orchestration panel/template/host/style and orchestration-facing locale strings.
  • Local browser smoke screenshot of the Codexmate Web UI tab was captured from http://127.0.0.1:18323/?tab=orchestration; cropped smoke image SHA256: c993357ed62b2e59fbb74a9488194d73bd650838aeab8c7ba9e8a6f1932b93bd.

Important scope note:

  • The screenshot is only a Codexmate Web UI tab smoke check. It is not a native VS Code/Kilo extension webview capture.

Known existing noise:

  • The unit runner may emit the existing search_sessions.py --limit -1 argparse warning on stderr, but the command exits 0 and reports all tests passed.

@coderabbitai re-review

@coderabbitai

coderabbitai Bot commented Jun 30, 2026

Copy link
Copy Markdown
Contributor

@awsl233777 Re-reviewing the latest orchestration-tab rewrite now, including the new Kilo/VS Code-style chat surface, the retained shim/bridge behavior, the privacy redaction safeguards, and the updated regression coverage.

✅ Action performed

Full review finished.

@awsl233777

Copy link
Copy Markdown
Collaborator Author

Update on c617770:

  • Removed the remaining legacy orchestration tab settings surface instead of masking it:
    • removed the header settings toggle
    • removed visible workspace/thread inputs
    • removed engine/run-mode selects and workflow suggestion buttons from the tab surface
    • removed the corresponding legacy settings/input CSS
  • Tightened the tab copy so the surface reads as a task chat instead of exposing host/adapter implementation language.
  • Updated the regression gate so the orchestration tab must not reintroduce task-sensitive-input, kilo-settings-popover, kilo-settings-row, kilo-input, startNewTaskWorkspaceSession, or the old workspace action entry.

Validation performed:

  • node tests/unit/run.mjs tests/unit/config-tabs-ui.test.mjs
    • All 744 tests passed
  • node tests/unit/run.mjs tests/unit/i18n-locales.test.mjs
    • All 744 tests passed
  • Legacy surface scan over template/CSS/precompiled bundle/locales: no hits for the removed settings/input/action/host strings.
  • CDP Web UI tab proof using intercepted /api responses (not a native VS Code extension-host screenshot):
    • 01-overview-empty sha256 9be02a41ed64615811c42d6ad64eaacec0988bb7bcfb947a0c366f9200830f59
    • 02-overview-active-queue-runs sha256 c1863b1545a48c7cbbfba85172ffd43647d1b9e95d5014cfa49252454096e395
    • 03-preview-plan-warnings sha256 8a94a78ca244d3298214689722a6660c0241d24d6ac1a75be231c9ebb152390a
    • 04-overview-error-redacted sha256 c766d67ebb6f151beb0d2af03222ee43d7cbdebb88ddfb9da706e4767df97aeb
    • 05-run-start-detail-running sha256 2a4cad6a09ff6b95cfbd29b4178b370f2b64b950bd241ebcc0c608b143f94686
    • 06-run-detail-failed-redacted sha256 1e770012259794ea8fba299f8c11f402dbfcdd7fe7629c466565457108b1f97b
    • The proof asserted the expected action chain (task-plan, task-run, task-run-detail) where applicable and verified that injected poison values for workspace paths, thread/run/task/node IDs, provider/model/endpoint, token, and raw stacktrace text were not present in the visible panel text.

@coderabbitai re-review

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 3

🧹 Nitpick comments (1)
tests/e2e/test-task-orchestration.js (1)

182-281: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win

Duplicated config scaffolding between writeOpenAiChatConfig and writeOpenAiChatFallbackConfig.

Both functions repeat the same mkdirSync calls, the identical [model_providers.local] TOML block, and near-identical JSON provider serialization. Any future change to the shared local-codex provider block or to the JSON provider shape now needs to be kept in sync across both functions (and any others repeating this pattern), risking silent drift between config.toml and task-openai-chat-provider.json fixtures.

Consider extracting a shared helper (e.g., writeCodexBaseConfig(tmpHome, mode) and buildOpenAiChatProviderJson(providers, selectedProvider)) that both functions call.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@tests/e2e/test-task-orchestration.js` around lines 182 - 281, The two fixture
helpers duplicate the same setup for the shared Codex config and provider JSON,
so extract the common pieces into reusable helpers. Move the repeated mkdirSync
calls, the shared [model_providers.local] TOML section, and the common provider
JSON construction in writeOpenAiChatConfig and writeOpenAiChatFallbackConfig
into shared functions such as writeCodexBaseConfig(tmpHome, mode) and
buildOpenAiChatProviderJson(...), then have both helpers call them and keep only
the mode-specific/provider-specific parts inline.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@web-ui/modules/i18n/locales/vi.mjs`:
- Around line 96-126: The new localization entries in vi.mjs are still raw
English, so update the affected i18n strings for the Local AI Service and
orchestration rebuilding UI with Vietnamese translations. Keep the same keys
under the locale object (including tab.localAi, side.localAi.meta,
kicker.localAi, title.localAi, subtitle.localAi, orchestration.rebuilding.*, all
localAi.* entries, and orchestration.openai.status.present) and translate them
consistently with the existing Vietnamese tone used elsewhere in vi.mjs.

In `@web-ui/partials/index/layout-header.html`:
- Around line 327-339: The Local AI tab meta in the layout header hardcodes the
word “providers” instead of using localization. Update the render logic in the
local-ai button section to replace the literal English suffix with an i18n
lookup, using a new locale key such as side.localAi.providerCount in the same
area that already calls t('tab.localAi') and t('side.localAi.meta'). Add the
corresponding translation entries to all locale files so the provider count
label is translated consistently.

In `@web-ui/partials/index/panel-orchestration.html`:
- Around line 25-27: The device settings gear in the panel is currently
hard-disabled and missing an action, so the modal cannot be opened from this
surface. Update the button in panel-orchestration.html to call
openTaskDeviceSettings() on click, and make disabled depend on the actual
rebuilding state instead of always being set; if this panel is not the right
entry point, move the launcher to the intended component.

---

Nitpick comments:
In `@tests/e2e/test-task-orchestration.js`:
- Around line 182-281: The two fixture helpers duplicate the same setup for the
shared Codex config and provider JSON, so extract the common pieces into
reusable helpers. Move the repeated mkdirSync calls, the shared
[model_providers.local] TOML section, and the common provider JSON construction
in writeOpenAiChatConfig and writeOpenAiChatFallbackConfig into shared functions
such as writeCodexBaseConfig(tmpHome, mode) and
buildOpenAiChatProviderJson(...), then have both helpers call them and keep only
the mode-specific/provider-specific parts inline.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 37da23a0-10c7-437b-b8cd-15fc12518e9e

📥 Commits

Reviewing files that changed from the base of the PR and between 0850d77 and 435ab7a.

📒 Files selected for processing (21)
  • cli.js
  • tests/e2e/test-task-orchestration.js
  • tests/unit/config-tabs-ui.test.mjs
  • tests/unit/web-ui-behavior-parity.test.mjs
  • tests/unit/web-ui-logic.test.mjs
  • web-ui/app.js
  • web-ui/index.html
  • web-ui/modules/app.computed.main-tabs.mjs
  • web-ui/modules/app.methods.navigation.mjs
  • web-ui/modules/app.methods.task-orchestration.mjs
  • web-ui/modules/i18n/locales/en.mjs
  • web-ui/modules/i18n/locales/ja.mjs
  • web-ui/modules/i18n/locales/vi.mjs
  • web-ui/modules/i18n/locales/zh-tw.mjs
  • web-ui/modules/i18n/locales/zh.mjs
  • web-ui/partials/index/layout-header.html
  • web-ui/partials/index/panel-local-ai.html
  • web-ui/partials/index/panel-orchestration.html
  • web-ui/res/web-ui-render.precompiled.js
  • web-ui/styles.css
  • web-ui/styles/local-ai-service.css
✅ Files skipped from review due to trivial changes (2)
  • web-ui/index.html
  • web-ui/modules/i18n/locales/en.mjs
🚧 Files skipped from review as they are similar to previous changes (7)
  • tests/unit/config-tabs-ui.test.mjs
  • tests/unit/web-ui-behavior-parity.test.mjs
  • tests/unit/web-ui-logic.test.mjs
  • cli.js
  • web-ui/modules/i18n/locales/zh-tw.mjs
  • web-ui/modules/app.computed.main-tabs.mjs
  • web-ui/modules/app.methods.task-orchestration.mjs

Comment thread web-ui/modules/i18n/locales/vi.mjs Outdated
Comment on lines +96 to +126
'field.endpoint': 'Endpoint',
'field.type': 'Type',
'tab.localAi': 'Local AI',
'side.localAi.meta': 'Provider adapters',
'kicker.localAi': 'Local service',
'title.localAi': 'Local AI Service',
'subtitle.localAi': 'Manage Claude/OpenAI providers for the local adapter service.',
'orchestration.rebuilding.status': 'Rebuilding',
'orchestration.rebuilding.title': 'Task tab is rebuilding',
'orchestration.rebuilding.body': 'This tab is read-only while task orchestration is refactored. Configure providers in Local AI Service.',
'orchestration.rebuilding.placeholder': 'Task input is disabled while this surface is rebuilding.',
'localAi.action.open': 'Open Local AI Service',
'localAi.action.newProvider': 'New provider',
'localAi.kicker': 'Local adapter',
'localAi.title': 'Local AI Service',
'localAi.body': 'Add Claude or OpenAI-compatible providers. The local service stores provider metadata and exposes a provider-adapter layer for task execution.',
'localAi.badge.localService': 'Local service',
'localAi.badge.providerAdapter': 'Provider adapter',
'localAi.badge.ready': 'Ready',
'localAi.badge.needsProvider': 'Needs provider',
'localAi.form.kicker': 'Provider setup',
'localAi.form.title': 'Add Claude or OpenAI provider',
'localAi.form.storeHint': 'Saved locally under ~/.codexmate; secrets are not rendered back.',
'localAi.providers.kicker': 'Configured providers',
'localAi.providers.title': 'Provider adapters',
'localAi.provider.ready': 'Ready',
'localAi.provider.incomplete': 'Incomplete',
'localAi.provider.enabled': 'Enabled',
'localAi.empty.title': 'No providers yet',
'localAi.empty.body': 'Add an OpenAI or Claude provider to activate the local AI service.',
'orchestration.openai.status.present': 'Present',

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

📐 Maintainability & Code Quality | 🟠 Major | ⚡ Quick win

New keys left untranslated (English text in Vietnamese locale).

Unlike the equivalent additions in zh.mjs (properly translated to Chinese), these new keys — tab.localAi, side.localAi.meta, kicker.localAi, title.localAi, subtitle.localAi, orchestration.rebuilding.*, all localAi.* keys, and orchestration.openai.status.present — are left as raw English strings. Vietnamese users will see English copy across the entire new Local AI Service surface and the orchestration rebuilding banner.

Please provide Vietnamese translations for these values.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@web-ui/modules/i18n/locales/vi.mjs` around lines 96 - 126, The new
localization entries in vi.mjs are still raw English, so update the affected
i18n strings for the Local AI Service and orchestration rebuilding UI with
Vietnamese translations. Keep the same keys under the locale object (including
tab.localAi, side.localAi.meta, kicker.localAi, title.localAi, subtitle.localAi,
orchestration.rebuilding.*, all localAi.* entries, and
orchestration.openai.status.present) and translate them consistently with the
existing Vietnamese tone used elsewhere in vi.mjs.

Comment on lines +327 to +339
<button
id="side-tab-local-ai"
data-main-tab="local-ai"
:aria-current="mainTab === 'local-ai' ? 'page' : null"
:class="['side-item', { active: isMainTabNavActive('local-ai') }]"
@pointerdown="onMainTabPointerDown('local-ai', $event)"
@click="onMainTabClick('local-ai', $event)">
<div class="side-item-title">{{ t('tab.localAi') }}</div>
<div class="side-item-meta">
<span>{{ t('side.localAi.meta') }}</span>
<span>{{ taskOrchestration.localAiServiceStatus && taskOrchestration.localAiServiceStatus.providerOptions ? taskOrchestration.localAiServiceStatus.providerOptions.length : 0 }} providers</span>
</div>
</button>

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

📐 Maintainability & Code Quality | 🟠 Major | ⚡ Quick win

Hardcoded "providers" text bypasses i18n.

Line 337 renders {{ ... }} providers as a literal English string, while the sibling orchestration meta line above it uses t(...) for localization. This will not translate for vi/ja/zh locales.

🌐 Suggested fix using i18n
-                            <span>{{ taskOrchestration.localAiServiceStatus && taskOrchestration.localAiServiceStatus.providerOptions ? taskOrchestration.localAiServiceStatus.providerOptions.length : 0 }} providers</span>
+                            <span>{{ t('side.localAi.providerCount', { count: taskOrchestration.localAiServiceStatus && taskOrchestration.localAiServiceStatus.providerOptions ? taskOrchestration.localAiServiceStatus.providerOptions.length : 0 }) }}</span>

A new locale key (e.g. side.localAi.providerCount) would need to be added to all locale files.

📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
<button
id="side-tab-local-ai"
data-main-tab="local-ai"
:aria-current="mainTab === 'local-ai' ? 'page' : null"
:class="['side-item', { active: isMainTabNavActive('local-ai') }]"
@pointerdown="onMainTabPointerDown('local-ai', $event)"
@click="onMainTabClick('local-ai', $event)">
<div class="side-item-title">{{ t('tab.localAi') }}</div>
<div class="side-item-meta">
<span>{{ t('side.localAi.meta') }}</span>
<span>{{ taskOrchestration.localAiServiceStatus && taskOrchestration.localAiServiceStatus.providerOptions ? taskOrchestration.localAiServiceStatus.providerOptions.length : 0 }} providers</span>
</div>
</button>
<button
id="side-tab-local-ai"
data-main-tab="local-ai"
:aria-current="mainTab === 'local-ai' ? 'page' : null"
:class="['side-item', { active: isMainTabNavActive('local-ai') }]"
`@pointerdown`="onMainTabPointerDown('local-ai', $event)"
`@click`="onMainTabClick('local-ai', $event)">
<div class="side-item-title">{{ t('tab.localAi') }}</div>
<div class="side-item-meta">
<span>{{ t('side.localAi.meta') }}</span>
<span>{{ t('side.localAi.providerCount', { count: taskOrchestration.localAiServiceStatus && taskOrchestration.localAiServiceStatus.providerOptions ? taskOrchestration.localAiServiceStatus.providerOptions.length : 0 }) }}</span>
</div>
</button>
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@web-ui/partials/index/layout-header.html` around lines 327 - 339, The Local
AI tab meta in the layout header hardcodes the word “providers” instead of using
localization. Update the render logic in the local-ai button section to replace
the literal English suffix with an i18n lookup, using a new locale key such as
side.localAi.providerCount in the same area that already calls t('tab.localAi')
and t('side.localAi.meta'). Add the corresponding translation entries to all
locale files so the provider count label is translated consistently.

Comment on lines 25 to 27
<button type="button" class="kilo-icon-button kilo-settings-button" disabled :aria-label="t('orchestration.rebuilding.status')" :title="t('orchestration.rebuilding.status')">
</button>

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
rg -n --no-heading 'kilo-settings-button|openTaskDeviceSettings|device.*[Mm]odal|kilo\.device\.open' web-ui/modules web-ui/partials -C 3

Repository: SakuraByteCore/codexmate

Length of output: 5876


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo '--- app.methods.task-orchestration.mjs around openTaskDeviceSettings ---'
sed -n '400,520p' web-ui/modules/app.methods.task-orchestration.mjs

echo
echo '--- search settingsOpen and device modal wiring ---'
rg -n --no-heading 'settingsOpen|openTaskDeviceSettings|orchestration\.kilo\.device\.open|orchestration\.kilo\.device\.title|orchestration\.kilo\.device\.body' web-ui -C 2

echo
echo '--- panel-orchestration.html around the settings button and surrounding state ---'
sed -n '1,180p' web-ui/partials/index/panel-orchestration.html

Repository: SakuraByteCore/codexmate

Length of output: 24196


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo '--- all settingsOpen references in web-ui ---'
rg -n --no-heading 'settingsOpen' web-ui -C 2

echo
echo '--- all openTaskDeviceSettings references in web-ui ---'
rg -n --no-heading 'openTaskDeviceSettings' web-ui -C 2

echo
echo '--- task orchestration template sections that mention device/settings modal terms ---'
rg -n --no-heading 'orchestration\.kilo\.device\.open|orchestration\.kilo\.device\.title|orchestration\.kilo\.device\.body|task-device|device-settings|settings-open|settingsOpen' web-ui/partials web-ui/modules -C 3

Repository: SakuraByteCore/codexmate

Length of output: 10104


Device settings launcher is disabled here
This gear is hard-disabled and has no @click, so the new device modal has no entry point from this panel. Wire it to openTaskDeviceSettings() and gate disabled on the actual rebuilding state, or move the launcher to the intended surface.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@web-ui/partials/index/panel-orchestration.html` around lines 25 - 27, The
device settings gear in the panel is currently hard-disabled and missing an
action, so the modal cannot be opened from this surface. Update the button in
panel-orchestration.html to call openTaskDeviceSettings() on click, and make
disabled depend on the actual rebuilding state instead of always being set; if
this panel is not the right entry point, move the launcher to the intended
component.

@awsl233777
awsl233777 force-pushed the fix/orchestration-privacy-redaction-main branch 2 times, most recently from a4320f9 to 5a9642b Compare July 16, 2026 00:21
@awsl233777 awsl233777 changed the title feat(local-ai): add local AI service provider management feat(kilocode): configure and launch from cli Jul 16, 2026
@awsl233777
awsl233777 force-pushed the fix/orchestration-privacy-redaction-main branch 10 times, most recently from 533b143 to 37d5524 Compare July 16, 2026 02:24
@awsl233777
awsl233777 force-pushed the fix/orchestration-privacy-redaction-main branch from 37d5524 to 3cfc27f Compare July 16, 2026 03:34
@ymkiux
ymkiux merged commit 304c819 into main Jul 16, 2026
12 checks passed
@ymkiux
ymkiux deleted the fix/orchestration-privacy-redaction-main branch July 16, 2026 14:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants